package com.demo.core.model;

import java.util.Date;
import java.util.List;

import com.demo.core.model.support.SimpleBaseModel;

/**
 * 会员表模型
 * 针对User在不同站点的身份
 * 
 * @author ryuu.kk
 */
public class Member extends SimpleBaseModel implements java.io.Serializable {

	/**
	 * 版本序列化ID
	 */
	private static final long serialVersionUID = -5655742646700650537L;
	/**
	 * 用户ID
	 */
	private Long userId;
	/**
	 * 会员所在站点
	 */
	private Long siteId;
	/**
	 * 昵称
	 */
	private String nickName;
	/**
	 * 注册时间
	 */
	private Date registerTime;
	/**
	 * 最后登录时间
	 */
	private Date lastLoginTime;
	/**
	 * 最后登录IP
	 */
	private String lastLoginIp;
	/**
	 * 当前登录时间
	 */
	private Date currentLoginTime;
	/**
	 * 当前登录IP
	 */
	private String currentLoginIp;
	/**
	 * 总登录次数
	 */
	private int loginCount;
	/**
	 * 会员有效期限
	 */
	private Date expireDay;
	/**
	 * 账号是否可用
	 */
	private Boolean enabled;
	/**
	 * 账号是否锁定
	 */
	private Boolean locked;
	/**
	 * 账号是否有效
	 */
	private Boolean isValid;
	
	/**
	 * 用户模型
	 */
	private User user;
	
	/**
	 * 会员角色列表
	 */
	private List<Role> roleList;
	
	public Long getUserId() {
		return userId;
	}
	public void setUserId(Long userId) {
		this.userId = userId;
	}
	public Long getSiteId() {
		return siteId;
	}
	public void setSiteId(Long siteId) {
		this.siteId = siteId;
	}
	public String getNickName() {
		return nickName;
	}
	public void setNickName(String nickName) {
		this.nickName = nickName;
	}
	public Date getRegisterTime() {
		return registerTime;
	}
	public void setRegisterTime(Date registerTime) {
		this.registerTime = registerTime;
	}
	public Date getLastLoginTime() {
		return lastLoginTime;
	}
	public void setLastLoginTime(Date lastLoginTime) {
		this.lastLoginTime = lastLoginTime;
	}
	public String getLastLoginIp() {
		return lastLoginIp;
	}
	public void setLastLoginIp(String lastLoginIp) {
		this.lastLoginIp = lastLoginIp;
	}
	public Date getCurrentLoginTime() {
		return currentLoginTime;
	}
	public void setCurrentLoginTime(Date currentLoginTime) {
		this.currentLoginTime = currentLoginTime;
	}
	public String getCurrentLoginIp() {
		return currentLoginIp;
	}
	public void setCurrentLoginIp(String currentLoginIp) {
		this.currentLoginIp = currentLoginIp;
	}
	public int getLoginCount() {
		return loginCount;
	}
	public void setLoginCount(int loginCount) {
		this.loginCount = loginCount;
	}
	public Date getExpireDay() {
		return expireDay;
	}
	public void setExpireDay(Date expireDay) {
		this.expireDay = expireDay;
	}
	public Boolean isEnabled() {
		return enabled;
	}
	public void setEnabled(Boolean enabled) {
		this.enabled = enabled;
	}
	public Boolean isLocked() {
		return locked;
	}
	public void setLocked(Boolean locked) {
		this.locked = locked;
	}
	public Boolean getIsValid() {
		return isValid;
	}
	public void setIsValid(Boolean isValid) {
		this.isValid = isValid;
	}
	public User getUser() {
		return user;
	}
	public void setUser(User user) {
		this.user = user;
	}
	public List<Role> getRoleList() {
		return roleList;
	}
	public void setRoleList(List<Role> roleList) {
		this.roleList = roleList;
	}
}
